<template>
  <el-dialog v-model="dialogVisible" title="选择成员" width="550" :before-close="handleClose">
    <team-new-user ref="SelectMemberNewTeamRefs" :pageType="'team'"
      ></team-new-user>
    <template #footer>
      <div class="dialog-footer">
        <!-- <el-button @click="dialogVisible = false">Cancel</el-button> -->
        <el-button type="primary" @click="dialogVisible = false">
          关闭
        </el-button>
      </div>
    </template>
  </el-dialog>
</template>

<script lang="ts" setup>
import TeamNewUser from "@/views/teamKnowdge/power/index.vue"
const dialogVisible = ref(false)
const SelectMemberNewTeamRefs = ref(null)
const route = useRoute()

const handleClose = () => {
  dialogVisible.value = false
}

const open = (row) => {
  dialogVisible.value = true
  nextTick(() => {
    SelectMemberNewTeamRefs.value.getTableData(route.query.teamId, row)
  })
}
defineExpose({
  open
})
</script>